package com.db4o.internal.odbgen.plugins.java.database;

import com.db4o.internal.odbgen.plugins.XmlSchemaElementList;
import com.db4o.odbgen.plugins.java.database.Unique;

/**
 * 
 * Contains all elements and attributes used inside XmlSchema 
 * that are processed by {@link Unique}.
 * @author liviug
 */
public enum UniqueXmlSchemaElement implements XmlSchemaElementList {
    /**
     * Used to specify whether a field is unique or not.
     * This is a boolean value.
     * If this is true, an index will be also created for that field.
     */
    UNIQUE("unique");

    private String _name;
    UniqueXmlSchemaElement(String name){
        this._name = name;
    }
    
    /**
     * See {@link XmlSchemaElementList} for details.
     */
    @Override
    public String getName() {
        return _name;
    }
}
